<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------
use think\facade\Route;

//前置仓
Route::group('warehouse', function () {

    Route::get('/', 'warehouse.index/index');
    Route::any('login', 'warehouse.index/login')->middleware([lc\middleware\ApiLogs::class]);
    Route::any('getCaptcha', 'warehouse.index/captcha')->middleware([lc\middleware\ApiLogs::class]);


//用户
    Route::group('admin', function () {

        Route::post('updatePassword', 'warehouse.index/updatePassword');

    })->middleware([lc\middleware\CheckAuth::class, lc\middleware\ApiLogs::class]);


//订单
    Route::group('order', function () {
        Route::post('createOrder', 'warehouse.Order/createOrder');
        Route::post('getGoodPrice', 'warehouse.Order/getGoodPrice');
        Route::post('userData', 'warehouse.Order/userData');
        Route::post('getOneCategory', 'warehouse.Order/getOneCategory');
        Route::post('getProductData', 'warehouse.Order/getProductData');
        //购物车
        Route::post('setCart', 'warehouse.Order/setCart');
        Route::post('setCartNum', 'warehouse.Order/setCartNum');
        Route::post('getTouristUid', 'warehouse.Order/getTouristUid');
        Route::post('cartPrice', 'warehouse.Order/cartPrice');
        Route::post('orderList', 'warehouse.Order/orderList');


    })->middleware([lc\middleware\CheckAuth::class, lc\middleware\ApiLogs::class]);


//分拣
    Route::group('sorting', function () {

        Route::post('selectOrder', 'warehouse.Sorting/selectOrder');
        Route::post('getGoodsInfo', 'warehouse.Sorting/getGoodsInfo');
        Route::post('getGoodsattribute', 'warehouse.Sorting/getGoodsattribute');
        Route::post('OrderSorting', 'warehouse.Sorting/OrderSorting');
        Route::post('removeGoodsInfo', 'warehouse.Sorting/removeGoodsInfo');
        Route::post('addGoodsAtt', 'warehouse.Sorting/addGoodsAtt');
        Route::post('resDelivery', 'warehouse.Sorting/resDelivery');
        Route::post('deliverGoods', 'warehouse.Sorting/deliverGoods');

    })->middleware([lc\middleware\CheckAuth::class, lc\middleware\ApiLogs::class]);
});



//工厂端
Route::group('factory', function () {

    Route::get('/', 'factory.index/index');
    Route::any('login', 'factory.index/login')->middleware([lc\middleware\ApiLogs::class]);
    Route::any('getCaptcha', 'factory.index/captcha')->middleware([lc\middleware\ApiLogs::class]);
    Route::any('adminInfo', 'factory.index/adminInfo')->middleware([lc\middleware\ApiLogs::class]);
    Route::any('staffData', 'factory.index/staffData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::any('updatePassword', 'factory.index/updatePassword')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::any('staffDataInfo', 'factory.index/staffDataInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::any('homeData', 'factory.index/homeData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);


    Route::post('orderGetOrderData', 'factory.order/getOrderData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderTodaySignData', 'factory.order/todaySignData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderGetOrderDataTwo', 'factory.order/getOrderDataTwo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderTodayData', 'factory.order/todayData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderJoinFactory', 'factory.order/joinFactory')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderAddOrderGood', 'factory.order/addorderGood')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('updateOrderStatus', 'factory.order/updateOrderStatus')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderGoodsAttribute', 'factory.order/goodsAttribute')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderRemoveGoodsInfo', 'factory.order/removeGoodsInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderEditAttribute', 'factory.order/editAttribute')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderGetGoodsInfo', 'factory.order/getGoodsInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderGoodsStain', 'factory.order/goodsStain')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderExamine', 'factory.order/examine')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderTodayExamine', 'factory.order/todayExamine')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderPutAway', 'factory.order/putaway')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderPackDeliver', 'factory.order/packDeliver')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('replenishmentOrder', 'factory.order/replenishmentOrder')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderLeaveFactory', 'factory.order/leaveFactory')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderList', 'factory.order/orderList')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('orderListInfo', 'factory.order/orderListInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('laundryList', 'factory.order/laundryList')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('statisticsData', 'factory.order/statisticsData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('upload', 'factory.order/upload')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('uploadFile', 'factory.order/uploadFile')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('clothingData', 'factory.order/clothingData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('subsidyData', 'factory.order/subsidyData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('revocationSubsidy', 'factory.order/revocationSubsidy')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('jdPrint', 'factory.order/jdPrint')->middleware([lc\middleware\ApiLogs::class]);


    Route::post('workData', 'factory.work/workData')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('workDataInfo', 'factory.work/workDataInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('factoryAddInfo', 'factory.work/factoryAddInfo')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);
    Route::post('factoryAppeal', 'factory.work/factoryAppeal')->middleware([lc\middleware\CheckAuth::class,lc\middleware\ApiLogs::class]);

});


